#include "syscall.h"

void initTests(){
	int lock1 = -1;
	int lock2 = -1;
	int cond1 = -1;
	int MV1 = -1;
	
	Printing("initializing everything!\n", ConsoleOutput, 0, 0);
	
	lock1 = CreateLock("lock1", 5);
	/*Printing("lock1 index = %i\n", ConsoleOutput, lock1, 0);*/
	Printing("lock1 created!\n", ConsoleOutput, 0, 0);
	if(lock1 == -1){
		Printing("Error when trying to create lock 1!\n", ConsoleOutput, 0, 0);
	}
	
	lock2 = CreateLock("lock1", 5);
	/*Printing("lock2 index = %i\n", ConsoleOutput, lock2, 0);*/
	Printing("lock1 created again!\n", ConsoleOutput, 0, 0);
	if(lock2 == -1){
		Printing("Error when trying to create lock 2!\n", ConsoleOutput, 0, 0);
	}

	cond1 = CreateCondition("condition1", 10);
	/*Printing("cond1 index = %i\n", ConsoleOutput, cond1, 0);*/
	Printing("condition1 created!\n", ConsoleOutput, 0, 0);
	if(cond1 == -1){
		Printing("Error when trying to create cond 1!\n", ConsoleOutput, 0, 0);
	}

	MV1 = CreateMonitor("monitor1", 8);
	/*Printing("monitor1 index = %i\n", ConsoleOutput, MV1, 0);*/
	Printing("monitor1 created!\n", ConsoleOutput, 0, 0);
	if(MV1 == -1){
		Printing("Error when trying to create MV 1!\n", ConsoleOutput, 0, 0);
	}
	
}

int main(){
	initTests();
	Exit(11);
}